package org.batatasframework.web.element;


public abstract class AbstractElementContent<Content> extends AbstractElement{
	
	protected Content content;
	
	public AbstractElementContent(String name) {
		super(name);
	}
	
	public void setContent(Content content) {
		this.content = content;
	}

	protected void elementClosed(StringBuilder html){
		if(null == content){
			html.append('>').append("</").append(name).append('>');
		}else{
			html.append('>').append(content).append("</").append(name).append('>');
		}
	}
}
